#ifndef __ILIB_CORE_ATOMIC_H_20120311__
#define __ILIB_CORE_ATOMIC_H_20120311__

class iAtomInt
{
public:
	iAtomInt()
	:_count(0)
	{

	}
	inline int operator++()
	{
		return ++_count;
	}
	inline int operator++(int)
	{
		return _count++;
	}
	inline int operator--()
	{
		return --_count;
	}
	inline int operator--(int)
	{
		return _count--;
	}
    operator int() { return _count; }

private:
	volatile int _count;
};

#endif  //__ILIB_CORE_ATOMIC_H_20120311__
